package com.vue.vuedemo.service.impl;

import com.vue.vuedemo.dao.ChatMapper;
import com.vue.vuedemo.pojo.Chat;
import com.vue.vuedemo.service.ChatService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service("ChatService")
public class ChatServiceImpl implements ChatService {

    @Resource
    public ChatMapper chatMapper;

    @Override
    public List<Chat> findAll(Integer cFpid, Integer cJpid) {
        return chatMapper.findAll(cFpid, cJpid);
    }

    @Override
    public void add(Chat chat) {
        chatMapper.add(chat);
    }

    @Override
    public void del(Integer cId) {
        chatMapper.del(cId);
    }

    @Override
    public Integer countChat(Integer cJpid) {
        return chatMapper.countChat(cJpid);
    }

    @Override
    public void chatUpdateType(Integer cJpid) {
        chatMapper.chatUpdateType(cJpid);
    }
}
